/**
 */
package com.logicfishsoftware.plugbench.wPPlugBench.impl;

import com.logicfishsoftware.plugbench.wPPlugBench.AdminPage;
import com.logicfishsoftware.plugbench.wPPlugBench.Function;
import com.logicfishsoftware.plugbench.wPPlugBench.Options;
import com.logicfishsoftware.plugbench.wPPlugBench.OptionsPage;
import com.logicfishsoftware.plugbench.wPPlugBench.Plugin;
import com.logicfishsoftware.plugbench.wPPlugBench.WPPlugBenchPackage;

import java.util.Collection;

import org.eclipse.emf.common.notify.Notification;
import org.eclipse.emf.common.notify.NotificationChain;

import org.eclipse.emf.common.util.EList;

import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.ecore.InternalEObject;

import org.eclipse.emf.ecore.impl.ENotificationImpl;
import org.eclipse.emf.ecore.impl.MinimalEObjectImpl;

import org.eclipse.emf.ecore.util.EDataTypeEList;
import org.eclipse.emf.ecore.util.EObjectContainmentEList;
import org.eclipse.emf.ecore.util.InternalEList;

/**
 * <!-- begin-user-doc -->
 * An implementation of the model object '<em><b>Plugin</b></em>'.
 * <!-- end-user-doc -->
 * <p>
 * The following features are implemented:
 * <ul>
 *   <li>{@link com.logicfishsoftware.plugbench.wPPlugBench.impl.PluginImpl#getImports <em>Imports</em>}</li>
 *   <li>{@link com.logicfishsoftware.plugbench.wPPlugBench.impl.PluginImpl#getType <em>Type</em>}</li>
 *   <li>{@link com.logicfishsoftware.plugbench.wPPlugBench.impl.PluginImpl#getName <em>Name</em>}</li>
 *   <li>{@link com.logicfishsoftware.plugbench.wPPlugBench.impl.PluginImpl#getPlatform <em>Platform</em>}</li>
 *   <li>{@link com.logicfishsoftware.plugbench.wPPlugBench.impl.PluginImpl#getTitle <em>Title</em>}</li>
 *   <li>{@link com.logicfishsoftware.plugbench.wPPlugBench.impl.PluginImpl#getVersion <em>Version</em>}</li>
 *   <li>{@link com.logicfishsoftware.plugbench.wPPlugBench.impl.PluginImpl#getPluginURI <em>Plugin URI</em>}</li>
 *   <li>{@link com.logicfishsoftware.plugbench.wPPlugBench.impl.PluginImpl#getDescription <em>Description</em>}</li>
 *   <li>{@link com.logicfishsoftware.plugbench.wPPlugBench.impl.PluginImpl#getAuthor <em>Author</em>}</li>
 *   <li>{@link com.logicfishsoftware.plugbench.wPPlugBench.impl.PluginImpl#getSkin <em>Skin</em>}</li>
 *   <li>{@link com.logicfishsoftware.plugbench.wPPlugBench.impl.PluginImpl#getInclude <em>Include</em>}</li>
 *   <li>{@link com.logicfishsoftware.plugbench.wPPlugBench.impl.PluginImpl#getScript <em>Script</em>}</li>
 *   <li>{@link com.logicfishsoftware.plugbench.wPPlugBench.impl.PluginImpl#getCss <em>Css</em>}</li>
 *   <li>{@link com.logicfishsoftware.plugbench.wPPlugBench.impl.PluginImpl#getAdminCSS <em>Admin CSS</em>}</li>
 *   <li>{@link com.logicfishsoftware.plugbench.wPPlugBench.impl.PluginImpl#getOptions <em>Options</em>}</li>
 *   <li>{@link com.logicfishsoftware.plugbench.wPPlugBench.impl.PluginImpl#getOptionsPage <em>Options Page</em>}</li>
 *   <li>{@link com.logicfishsoftware.plugbench.wPPlugBench.impl.PluginImpl#getAdminPages <em>Admin Pages</em>}</li>
 *   <li>{@link com.logicfishsoftware.plugbench.wPPlugBench.impl.PluginImpl#getFunctions <em>Functions</em>}</li>
 * </ul>
 * </p>
 *
 * @generated
 */
public class PluginImpl extends MinimalEObjectImpl.Container implements Plugin
{
  /**
   * The cached value of the '{@link #getImports() <em>Imports</em>}' attribute list.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getImports()
   * @generated
   * @ordered
   */
  protected EList<String> imports;

  /**
   * The default value of the '{@link #getType() <em>Type</em>}' attribute.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getType()
   * @generated
   * @ordered
   */
  protected static final String TYPE_EDEFAULT = null;

  /**
   * The cached value of the '{@link #getType() <em>Type</em>}' attribute.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getType()
   * @generated
   * @ordered
   */
  protected String type = TYPE_EDEFAULT;

  /**
   * The default value of the '{@link #getName() <em>Name</em>}' attribute.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getName()
   * @generated
   * @ordered
   */
  protected static final String NAME_EDEFAULT = null;

  /**
   * The cached value of the '{@link #getName() <em>Name</em>}' attribute.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getName()
   * @generated
   * @ordered
   */
  protected String name = NAME_EDEFAULT;

  /**
   * The default value of the '{@link #getPlatform() <em>Platform</em>}' attribute.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getPlatform()
   * @generated
   * @ordered
   */
  protected static final String PLATFORM_EDEFAULT = null;

  /**
   * The cached value of the '{@link #getPlatform() <em>Platform</em>}' attribute.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getPlatform()
   * @generated
   * @ordered
   */
  protected String platform = PLATFORM_EDEFAULT;

  /**
   * The default value of the '{@link #getTitle() <em>Title</em>}' attribute.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getTitle()
   * @generated
   * @ordered
   */
  protected static final String TITLE_EDEFAULT = null;

  /**
   * The cached value of the '{@link #getTitle() <em>Title</em>}' attribute.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getTitle()
   * @generated
   * @ordered
   */
  protected String title = TITLE_EDEFAULT;

  /**
   * The default value of the '{@link #getVersion() <em>Version</em>}' attribute.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getVersion()
   * @generated
   * @ordered
   */
  protected static final String VERSION_EDEFAULT = null;

  /**
   * The cached value of the '{@link #getVersion() <em>Version</em>}' attribute.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getVersion()
   * @generated
   * @ordered
   */
  protected String version = VERSION_EDEFAULT;

  /**
   * The default value of the '{@link #getPluginURI() <em>Plugin URI</em>}' attribute.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getPluginURI()
   * @generated
   * @ordered
   */
  protected static final String PLUGIN_URI_EDEFAULT = null;

  /**
   * The cached value of the '{@link #getPluginURI() <em>Plugin URI</em>}' attribute.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getPluginURI()
   * @generated
   * @ordered
   */
  protected String pluginURI = PLUGIN_URI_EDEFAULT;

  /**
   * The default value of the '{@link #getDescription() <em>Description</em>}' attribute.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getDescription()
   * @generated
   * @ordered
   */
  protected static final String DESCRIPTION_EDEFAULT = null;

  /**
   * The cached value of the '{@link #getDescription() <em>Description</em>}' attribute.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getDescription()
   * @generated
   * @ordered
   */
  protected String description = DESCRIPTION_EDEFAULT;

  /**
   * The default value of the '{@link #getAuthor() <em>Author</em>}' attribute.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getAuthor()
   * @generated
   * @ordered
   */
  protected static final String AUTHOR_EDEFAULT = null;

  /**
   * The cached value of the '{@link #getAuthor() <em>Author</em>}' attribute.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getAuthor()
   * @generated
   * @ordered
   */
  protected String author = AUTHOR_EDEFAULT;

  /**
   * The default value of the '{@link #getSkin() <em>Skin</em>}' attribute.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getSkin()
   * @generated
   * @ordered
   */
  protected static final String SKIN_EDEFAULT = null;

  /**
   * The cached value of the '{@link #getSkin() <em>Skin</em>}' attribute.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getSkin()
   * @generated
   * @ordered
   */
  protected String skin = SKIN_EDEFAULT;

  /**
   * The cached value of the '{@link #getInclude() <em>Include</em>}' attribute list.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getInclude()
   * @generated
   * @ordered
   */
  protected EList<String> include;

  /**
   * The cached value of the '{@link #getScript() <em>Script</em>}' attribute list.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getScript()
   * @generated
   * @ordered
   */
  protected EList<String> script;

  /**
   * The cached value of the '{@link #getCss() <em>Css</em>}' attribute list.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getCss()
   * @generated
   * @ordered
   */
  protected EList<String> css;

  /**
   * The cached value of the '{@link #getAdminCSS() <em>Admin CSS</em>}' attribute list.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getAdminCSS()
   * @generated
   * @ordered
   */
  protected EList<String> adminCSS;

  /**
   * The cached value of the '{@link #getOptions() <em>Options</em>}' containment reference.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getOptions()
   * @generated
   * @ordered
   */
  protected Options options;

  /**
   * The cached value of the '{@link #getOptionsPage() <em>Options Page</em>}' containment reference list.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getOptionsPage()
   * @generated
   * @ordered
   */
  protected EList<OptionsPage> optionsPage;

  /**
   * The cached value of the '{@link #getAdminPages() <em>Admin Pages</em>}' containment reference list.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getAdminPages()
   * @generated
   * @ordered
   */
  protected EList<AdminPage> adminPages;

  /**
   * The cached value of the '{@link #getFunctions() <em>Functions</em>}' containment reference list.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @see #getFunctions()
   * @generated
   * @ordered
   */
  protected EList<Function> functions;

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  protected PluginImpl()
  {
    super();
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  @Override
  protected EClass eStaticClass()
  {
    return WPPlugBenchPackage.Literals.PLUGIN;
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public EList<String> getImports()
  {
    if (imports == null)
    {
      imports = new EDataTypeEList<String>(String.class, this, WPPlugBenchPackage.PLUGIN__IMPORTS);
    }
    return imports;
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public String getType()
  {
    return type;
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public void setType(String newType)
  {
    String oldType = type;
    type = newType;
    if (eNotificationRequired())
      eNotify(new ENotificationImpl(this, Notification.SET, WPPlugBenchPackage.PLUGIN__TYPE, oldType, type));
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public String getName()
  {
    return name;
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public void setName(String newName)
  {
    String oldName = name;
    name = newName;
    if (eNotificationRequired())
      eNotify(new ENotificationImpl(this, Notification.SET, WPPlugBenchPackage.PLUGIN__NAME, oldName, name));
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public String getPlatform()
  {
    return platform;
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public void setPlatform(String newPlatform)
  {
    String oldPlatform = platform;
    platform = newPlatform;
    if (eNotificationRequired())
      eNotify(new ENotificationImpl(this, Notification.SET, WPPlugBenchPackage.PLUGIN__PLATFORM, oldPlatform, platform));
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public String getTitle()
  {
    return title;
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public void setTitle(String newTitle)
  {
    String oldTitle = title;
    title = newTitle;
    if (eNotificationRequired())
      eNotify(new ENotificationImpl(this, Notification.SET, WPPlugBenchPackage.PLUGIN__TITLE, oldTitle, title));
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public String getVersion()
  {
    return version;
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public void setVersion(String newVersion)
  {
    String oldVersion = version;
    version = newVersion;
    if (eNotificationRequired())
      eNotify(new ENotificationImpl(this, Notification.SET, WPPlugBenchPackage.PLUGIN__VERSION, oldVersion, version));
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public String getPluginURI()
  {
    return pluginURI;
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public void setPluginURI(String newPluginURI)
  {
    String oldPluginURI = pluginURI;
    pluginURI = newPluginURI;
    if (eNotificationRequired())
      eNotify(new ENotificationImpl(this, Notification.SET, WPPlugBenchPackage.PLUGIN__PLUGIN_URI, oldPluginURI, pluginURI));
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public String getDescription()
  {
    return description;
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public void setDescription(String newDescription)
  {
    String oldDescription = description;
    description = newDescription;
    if (eNotificationRequired())
      eNotify(new ENotificationImpl(this, Notification.SET, WPPlugBenchPackage.PLUGIN__DESCRIPTION, oldDescription, description));
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public String getAuthor()
  {
    return author;
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public void setAuthor(String newAuthor)
  {
    String oldAuthor = author;
    author = newAuthor;
    if (eNotificationRequired())
      eNotify(new ENotificationImpl(this, Notification.SET, WPPlugBenchPackage.PLUGIN__AUTHOR, oldAuthor, author));
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public String getSkin()
  {
    return skin;
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public void setSkin(String newSkin)
  {
    String oldSkin = skin;
    skin = newSkin;
    if (eNotificationRequired())
      eNotify(new ENotificationImpl(this, Notification.SET, WPPlugBenchPackage.PLUGIN__SKIN, oldSkin, skin));
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public EList<String> getInclude()
  {
    if (include == null)
    {
      include = new EDataTypeEList<String>(String.class, this, WPPlugBenchPackage.PLUGIN__INCLUDE);
    }
    return include;
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public EList<String> getScript()
  {
    if (script == null)
    {
      script = new EDataTypeEList<String>(String.class, this, WPPlugBenchPackage.PLUGIN__SCRIPT);
    }
    return script;
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public EList<String> getCss()
  {
    if (css == null)
    {
      css = new EDataTypeEList<String>(String.class, this, WPPlugBenchPackage.PLUGIN__CSS);
    }
    return css;
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public EList<String> getAdminCSS()
  {
    if (adminCSS == null)
    {
      adminCSS = new EDataTypeEList<String>(String.class, this, WPPlugBenchPackage.PLUGIN__ADMIN_CSS);
    }
    return adminCSS;
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public Options getOptions()
  {
    return options;
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public NotificationChain basicSetOptions(Options newOptions, NotificationChain msgs)
  {
    Options oldOptions = options;
    options = newOptions;
    if (eNotificationRequired())
    {
      ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, WPPlugBenchPackage.PLUGIN__OPTIONS, oldOptions, newOptions);
      if (msgs == null) msgs = notification; else msgs.add(notification);
    }
    return msgs;
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public void setOptions(Options newOptions)
  {
    if (newOptions != options)
    {
      NotificationChain msgs = null;
      if (options != null)
        msgs = ((InternalEObject)options).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - WPPlugBenchPackage.PLUGIN__OPTIONS, null, msgs);
      if (newOptions != null)
        msgs = ((InternalEObject)newOptions).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - WPPlugBenchPackage.PLUGIN__OPTIONS, null, msgs);
      msgs = basicSetOptions(newOptions, msgs);
      if (msgs != null) msgs.dispatch();
    }
    else if (eNotificationRequired())
      eNotify(new ENotificationImpl(this, Notification.SET, WPPlugBenchPackage.PLUGIN__OPTIONS, newOptions, newOptions));
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public EList<OptionsPage> getOptionsPage()
  {
    if (optionsPage == null)
    {
      optionsPage = new EObjectContainmentEList<OptionsPage>(OptionsPage.class, this, WPPlugBenchPackage.PLUGIN__OPTIONS_PAGE);
    }
    return optionsPage;
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public EList<AdminPage> getAdminPages()
  {
    if (adminPages == null)
    {
      adminPages = new EObjectContainmentEList<AdminPage>(AdminPage.class, this, WPPlugBenchPackage.PLUGIN__ADMIN_PAGES);
    }
    return adminPages;
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public EList<Function> getFunctions()
  {
    if (functions == null)
    {
      functions = new EObjectContainmentEList<Function>(Function.class, this, WPPlugBenchPackage.PLUGIN__FUNCTIONS);
    }
    return functions;
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  @Override
  public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs)
  {
    switch (featureID)
    {
      case WPPlugBenchPackage.PLUGIN__OPTIONS:
        return basicSetOptions(null, msgs);
      case WPPlugBenchPackage.PLUGIN__OPTIONS_PAGE:
        return ((InternalEList<?>)getOptionsPage()).basicRemove(otherEnd, msgs);
      case WPPlugBenchPackage.PLUGIN__ADMIN_PAGES:
        return ((InternalEList<?>)getAdminPages()).basicRemove(otherEnd, msgs);
      case WPPlugBenchPackage.PLUGIN__FUNCTIONS:
        return ((InternalEList<?>)getFunctions()).basicRemove(otherEnd, msgs);
    }
    return super.eInverseRemove(otherEnd, featureID, msgs);
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  @Override
  public Object eGet(int featureID, boolean resolve, boolean coreType)
  {
    switch (featureID)
    {
      case WPPlugBenchPackage.PLUGIN__IMPORTS:
        return getImports();
      case WPPlugBenchPackage.PLUGIN__TYPE:
        return getType();
      case WPPlugBenchPackage.PLUGIN__NAME:
        return getName();
      case WPPlugBenchPackage.PLUGIN__PLATFORM:
        return getPlatform();
      case WPPlugBenchPackage.PLUGIN__TITLE:
        return getTitle();
      case WPPlugBenchPackage.PLUGIN__VERSION:
        return getVersion();
      case WPPlugBenchPackage.PLUGIN__PLUGIN_URI:
        return getPluginURI();
      case WPPlugBenchPackage.PLUGIN__DESCRIPTION:
        return getDescription();
      case WPPlugBenchPackage.PLUGIN__AUTHOR:
        return getAuthor();
      case WPPlugBenchPackage.PLUGIN__SKIN:
        return getSkin();
      case WPPlugBenchPackage.PLUGIN__INCLUDE:
        return getInclude();
      case WPPlugBenchPackage.PLUGIN__SCRIPT:
        return getScript();
      case WPPlugBenchPackage.PLUGIN__CSS:
        return getCss();
      case WPPlugBenchPackage.PLUGIN__ADMIN_CSS:
        return getAdminCSS();
      case WPPlugBenchPackage.PLUGIN__OPTIONS:
        return getOptions();
      case WPPlugBenchPackage.PLUGIN__OPTIONS_PAGE:
        return getOptionsPage();
      case WPPlugBenchPackage.PLUGIN__ADMIN_PAGES:
        return getAdminPages();
      case WPPlugBenchPackage.PLUGIN__FUNCTIONS:
        return getFunctions();
    }
    return super.eGet(featureID, resolve, coreType);
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  @SuppressWarnings("unchecked")
  @Override
  public void eSet(int featureID, Object newValue)
  {
    switch (featureID)
    {
      case WPPlugBenchPackage.PLUGIN__IMPORTS:
        getImports().clear();
        getImports().addAll((Collection<? extends String>)newValue);
        return;
      case WPPlugBenchPackage.PLUGIN__TYPE:
        setType((String)newValue);
        return;
      case WPPlugBenchPackage.PLUGIN__NAME:
        setName((String)newValue);
        return;
      case WPPlugBenchPackage.PLUGIN__PLATFORM:
        setPlatform((String)newValue);
        return;
      case WPPlugBenchPackage.PLUGIN__TITLE:
        setTitle((String)newValue);
        return;
      case WPPlugBenchPackage.PLUGIN__VERSION:
        setVersion((String)newValue);
        return;
      case WPPlugBenchPackage.PLUGIN__PLUGIN_URI:
        setPluginURI((String)newValue);
        return;
      case WPPlugBenchPackage.PLUGIN__DESCRIPTION:
        setDescription((String)newValue);
        return;
      case WPPlugBenchPackage.PLUGIN__AUTHOR:
        setAuthor((String)newValue);
        return;
      case WPPlugBenchPackage.PLUGIN__SKIN:
        setSkin((String)newValue);
        return;
      case WPPlugBenchPackage.PLUGIN__INCLUDE:
        getInclude().clear();
        getInclude().addAll((Collection<? extends String>)newValue);
        return;
      case WPPlugBenchPackage.PLUGIN__SCRIPT:
        getScript().clear();
        getScript().addAll((Collection<? extends String>)newValue);
        return;
      case WPPlugBenchPackage.PLUGIN__CSS:
        getCss().clear();
        getCss().addAll((Collection<? extends String>)newValue);
        return;
      case WPPlugBenchPackage.PLUGIN__ADMIN_CSS:
        getAdminCSS().clear();
        getAdminCSS().addAll((Collection<? extends String>)newValue);
        return;
      case WPPlugBenchPackage.PLUGIN__OPTIONS:
        setOptions((Options)newValue);
        return;
      case WPPlugBenchPackage.PLUGIN__OPTIONS_PAGE:
        getOptionsPage().clear();
        getOptionsPage().addAll((Collection<? extends OptionsPage>)newValue);
        return;
      case WPPlugBenchPackage.PLUGIN__ADMIN_PAGES:
        getAdminPages().clear();
        getAdminPages().addAll((Collection<? extends AdminPage>)newValue);
        return;
      case WPPlugBenchPackage.PLUGIN__FUNCTIONS:
        getFunctions().clear();
        getFunctions().addAll((Collection<? extends Function>)newValue);
        return;
    }
    super.eSet(featureID, newValue);
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  @Override
  public void eUnset(int featureID)
  {
    switch (featureID)
    {
      case WPPlugBenchPackage.PLUGIN__IMPORTS:
        getImports().clear();
        return;
      case WPPlugBenchPackage.PLUGIN__TYPE:
        setType(TYPE_EDEFAULT);
        return;
      case WPPlugBenchPackage.PLUGIN__NAME:
        setName(NAME_EDEFAULT);
        return;
      case WPPlugBenchPackage.PLUGIN__PLATFORM:
        setPlatform(PLATFORM_EDEFAULT);
        return;
      case WPPlugBenchPackage.PLUGIN__TITLE:
        setTitle(TITLE_EDEFAULT);
        return;
      case WPPlugBenchPackage.PLUGIN__VERSION:
        setVersion(VERSION_EDEFAULT);
        return;
      case WPPlugBenchPackage.PLUGIN__PLUGIN_URI:
        setPluginURI(PLUGIN_URI_EDEFAULT);
        return;
      case WPPlugBenchPackage.PLUGIN__DESCRIPTION:
        setDescription(DESCRIPTION_EDEFAULT);
        return;
      case WPPlugBenchPackage.PLUGIN__AUTHOR:
        setAuthor(AUTHOR_EDEFAULT);
        return;
      case WPPlugBenchPackage.PLUGIN__SKIN:
        setSkin(SKIN_EDEFAULT);
        return;
      case WPPlugBenchPackage.PLUGIN__INCLUDE:
        getInclude().clear();
        return;
      case WPPlugBenchPackage.PLUGIN__SCRIPT:
        getScript().clear();
        return;
      case WPPlugBenchPackage.PLUGIN__CSS:
        getCss().clear();
        return;
      case WPPlugBenchPackage.PLUGIN__ADMIN_CSS:
        getAdminCSS().clear();
        return;
      case WPPlugBenchPackage.PLUGIN__OPTIONS:
        setOptions((Options)null);
        return;
      case WPPlugBenchPackage.PLUGIN__OPTIONS_PAGE:
        getOptionsPage().clear();
        return;
      case WPPlugBenchPackage.PLUGIN__ADMIN_PAGES:
        getAdminPages().clear();
        return;
      case WPPlugBenchPackage.PLUGIN__FUNCTIONS:
        getFunctions().clear();
        return;
    }
    super.eUnset(featureID);
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  @Override
  public boolean eIsSet(int featureID)
  {
    switch (featureID)
    {
      case WPPlugBenchPackage.PLUGIN__IMPORTS:
        return imports != null && !imports.isEmpty();
      case WPPlugBenchPackage.PLUGIN__TYPE:
        return TYPE_EDEFAULT == null ? type != null : !TYPE_EDEFAULT.equals(type);
      case WPPlugBenchPackage.PLUGIN__NAME:
        return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name);
      case WPPlugBenchPackage.PLUGIN__PLATFORM:
        return PLATFORM_EDEFAULT == null ? platform != null : !PLATFORM_EDEFAULT.equals(platform);
      case WPPlugBenchPackage.PLUGIN__TITLE:
        return TITLE_EDEFAULT == null ? title != null : !TITLE_EDEFAULT.equals(title);
      case WPPlugBenchPackage.PLUGIN__VERSION:
        return VERSION_EDEFAULT == null ? version != null : !VERSION_EDEFAULT.equals(version);
      case WPPlugBenchPackage.PLUGIN__PLUGIN_URI:
        return PLUGIN_URI_EDEFAULT == null ? pluginURI != null : !PLUGIN_URI_EDEFAULT.equals(pluginURI);
      case WPPlugBenchPackage.PLUGIN__DESCRIPTION:
        return DESCRIPTION_EDEFAULT == null ? description != null : !DESCRIPTION_EDEFAULT.equals(description);
      case WPPlugBenchPackage.PLUGIN__AUTHOR:
        return AUTHOR_EDEFAULT == null ? author != null : !AUTHOR_EDEFAULT.equals(author);
      case WPPlugBenchPackage.PLUGIN__SKIN:
        return SKIN_EDEFAULT == null ? skin != null : !SKIN_EDEFAULT.equals(skin);
      case WPPlugBenchPackage.PLUGIN__INCLUDE:
        return include != null && !include.isEmpty();
      case WPPlugBenchPackage.PLUGIN__SCRIPT:
        return script != null && !script.isEmpty();
      case WPPlugBenchPackage.PLUGIN__CSS:
        return css != null && !css.isEmpty();
      case WPPlugBenchPackage.PLUGIN__ADMIN_CSS:
        return adminCSS != null && !adminCSS.isEmpty();
      case WPPlugBenchPackage.PLUGIN__OPTIONS:
        return options != null;
      case WPPlugBenchPackage.PLUGIN__OPTIONS_PAGE:
        return optionsPage != null && !optionsPage.isEmpty();
      case WPPlugBenchPackage.PLUGIN__ADMIN_PAGES:
        return adminPages != null && !adminPages.isEmpty();
      case WPPlugBenchPackage.PLUGIN__FUNCTIONS:
        return functions != null && !functions.isEmpty();
    }
    return super.eIsSet(featureID);
  }

  /**
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  @Override
  public String toString()
  {
    if (eIsProxy()) return super.toString();

    StringBuffer result = new StringBuffer(super.toString());
    result.append(" (imports: ");
    result.append(imports);
    result.append(", type: ");
    result.append(type);
    result.append(", name: ");
    result.append(name);
    result.append(", platform: ");
    result.append(platform);
    result.append(", title: ");
    result.append(title);
    result.append(", version: ");
    result.append(version);
    result.append(", pluginURI: ");
    result.append(pluginURI);
    result.append(", description: ");
    result.append(description);
    result.append(", author: ");
    result.append(author);
    result.append(", skin: ");
    result.append(skin);
    result.append(", include: ");
    result.append(include);
    result.append(", script: ");
    result.append(script);
    result.append(", css: ");
    result.append(css);
    result.append(", adminCSS: ");
    result.append(adminCSS);
    result.append(')');
    return result.toString();
  }

} //PluginImpl
